package com.cdream.basic.spring.factorybean;

import com.cdream.basic.spring.factorybean.circle.TestA;
import org.springframework.context.support.ClassPathXmlApplicationContext;

/**
 * @author cdream
 * @date 10/5/21
 */
public class XmlTest {
    public static void main(String[] args) {
        ClassPathXmlApplicationContext applicationContext = new ClassPathXmlApplicationContext("springs.xml");
        // CarAware bean = applicationContext.getBean(CarAware.class);
        // Car car1 = (Car) applicationContext.getBean("car2");
        // CarSon carSon = applicationContext.getBean(CarSon.class);
        // Console.log(car1);
        // Console.log(carSon);
        TestA bean = applicationContext.getBean(TestA.class);
        bean.say();
    }
}
